/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.klikmee.sms.core.base.dao;

import java.util.List;

import com.klikmee.sms.core.model.OutgoingMessage;
import com.klikmee.sms.core.model.Provider;
import com.klikmee.sms.core.model.Service;

/**
 *
 * @author makcro
 */
public interface OutgoingMessageFacadeLocal {

    void create( OutgoingMessage outgoingMessage );

    void edit( OutgoingMessage outgoingMessage );

    void remove( OutgoingMessage outgoingMessage );

    OutgoingMessage find( Object id );

    List<OutgoingMessage> findAll();

    List<OutgoingMessage> findRange( int[] range );

    int count();

    public OutgoingMessage findByProvidersMessageIDAndProviderName( java.lang.String providersMessageID, java.lang.String providerName );

    public java.lang.Long findNumberOfMessagesByProviderAndProvidersMessageId( Provider provider, java.lang.String providersMessageID );

    public OutgoingMessage findByMessageIDAndProvider( java.lang.Long messageID, java.lang.String providerName );

    public java.util.List<OutgoingMessage> findMessagesForSending();

    public OutgoingMessage refresh(OutgoingMessage message);

    public java.util.List<OutgoingMessage> findDeliveredByService( Service service );

    public java.util.List<OutgoingMessage> findDeliveredByServiceAndTime( Service service, java.util.Date time );
}
